package cn.tedu.csmall.product.repsitory;

import cn.tedu.csmall.product.pojo.vo.BrandListItemVO;
import cn.tedu.csmall.product.pojo.vo.BrandStandardVO;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Repository;

import java.util.Collection;
import java.util.List;
import java.util.Set;
import java.util.concurrent.TimeUnit;

/**
 * 处理品牌数据缓存的仓库接口...
 */
public interface IBrandRedisRepository {
    String BRAND_ITEM_KEY_PREFIX="brand:time:";

    String BRAND_LIST_KEY="brand:list:";

    void put(BrandStandardVO value);

    void put(BrandStandardVO brand, long t, TimeUnit timeUnit);

    void putList(List<BrandListItemVO> brand);

    Boolean deleteItem(Long id);

    Boolean deleteList();

    Long deleteAll(Collection<String> keys);

    List<BrandListItemVO>getList();

    BrandStandardVO get(Long id);

    Set<String> getAllKeys();

}
